h=eval(input("请输入本月总收入:"))
g=h-5000
if g<=0:
    s=0
elif 0<g<=1500:
    s=g*0.03
elif 1500<g<=4500:
    s=(g-1500)*0.1+1500*0.03
elif 4500<g<=9000:
    s=(g-4500)*0.2+(g-1500)*0.1+1500*0.03
elif 9000<g<=35000:
    s=(g-9000)*0.25+(g-4500)*0.2+(g-1500)*0.1+1500*0.03
elif 35000<g<=55000:
    s=(g-35000)*0.3+(g-9000)*0.25+(g-4500)*0.2+(g-1500)*0.1+1500*0.03
elif  55000<g<=80000:
    s=(g-55000)*0.35+(g-35000)*0.3+(g-9000)*0.25+(g-4500)*0.2+(g-1500)*0.1+1500*0.03
elif g>=80000:
    s=(g-80000)*0,45+(g-55000)*0.35+(g-35000)*0.3+(g-9000)*0.25+(g-4500)*0.2+(g-1500)*0.1+1500*0.03
print("本月的税收：{}".format(s))